﻿Imports System.Data.Odbc
Imports System.Data.OleDb
Imports Entidades
Imports Negocio

Public Class FormProducto
    Dim ingreso As daoProducto
    Dim productos As Producto

    Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged

    End Sub

    Private Sub FormProducto_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        productos = New Producto()
        ingreso = New daoProducto()
    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        productos.pid1 = t1.Text
        productos.pid2 = t2.Text
        productos.pid3 = t3.Text
        If ingreso.AltaProducto(productos) Then
            MsgBox("todo bien")
        Else
            MsgBox("todo mal")
        End If

    End Sub
End Class